window.onload = function(){
$(function(){
$.get("http://47.104.244.134:8080/goodstypelist.do", {
					l: 2
				}).done(data => {
					console.log(data);
				})
				$.get("http://47.104.244.134:8080/goodsbytid.do", {
					tid: 13,
					page: 1,
					limit: 5
				}).done(data => {
					console.log(data);
					if(data.code == 200){
						console.log(data.data);
						let pArray = data.data
						let html =''
						for(let i=1;i<pArray.length;i++){
							let pObj = pArray[i]
							console.log(pObj)
							
							 html+= `
								<div id="shouji${i+1-1}">
									<a href='detail.html?id=${pObj.id}'><img src='${pObj.picurl}'>
										<h5>'${pObj.info}'</h5>
										<p>'${pObj.name}'</p>
									</a>
								</div>
							`
						}
						$('#shouj').html(html)

					}
					
					
				})	
})	
}

				